<?php

class SupprimerFilmAction extends Action{
	
	function execute( HttpRequest $request ){
			
		$DAOfactory=AbstractDAOFactory::getDaoFactory(AbstractDAOFactory::MYSQL);
		$filmDAO=$DAOfactory->getFilmDAO();
		$filmDAO->delete($request->getParameter('idfilm'));
		$listeFilms=$filmDAO->getAll();
		$request->addMessage('Supression effectuee');
		$request->addObject('listeFilms',$listeFilms);
		return self::ACTION_DEFAULT;
		
		

		
	}
	
	
	
}